Make run_spotless.sh more verbose and strict - #2485
Open
imotov wants to merge 2 commits into
Open
Conversation
Some developers ran into issues with spotless-fmt skipping formatting silently on their local machines and then failing in CI. This PR now fails if there are any modified Java files and prints a warning if there are no changed Java files and Maven is not present.
Contributor
Author
|
/ok to test 7f33e33 |
jamxia155
reviewed
Aug 18, 2026
Contributor
Author
|
/ok to test eb3ffbd |
jameslamb
approved these changes
Aug 19, 2026
jameslamb
left a comment
Member
There was a problem hiding this comment.
So if I understand it, this makes it like "if you're touching a Java file, you have to have maven installed for pre-commit to work"?
Fair enough, not going to get in the way of that. You might face pushback from folks who make C++ changes and mechanically apply changes to the Java bindings based on those, but definitely worth experimenting with.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Some developers ran into issues with spotless-fmt skipping formatting silently on their local machines and then failing in CI. This PR now fails if there are any modified Java files and prints a warning if there are no changed Java files and Maven is not present.
Follow-up for #2361